package com.jackstraw.jack_base.mq.rocketmq.bean.listener;

import com.jackstraw.jack_base.mq.rocketmq.bean.TrListenerEntity;
import com.jackstraw.jack_base.mq.rocketmq.bean.enums.TransactionStateEnum;

/**
 * 事务消息最终执行者
 */
public interface ProducerTxService {

    /**
     * 事务消息中Header中要包含的头名称
     */
    public static final String PRODUCER_TX_SERVICE_BEAN_NAME = "producerTxServiceBeanName";


    TransactionStateEnum executeLocalTransaction(TrListenerEntity trListenerEntity);

    TransactionStateEnum checkLocalTransaction(TrListenerEntity trListenerEntity);


}
